<?php
require './include/common.inc.php';
require 'content.class.php';

$site_id = get_current_site();
$content = new content('category');
$content_single = $content->get_by_rel($cid);
if(empty($content_single))
{
     showmessage('没有该新闻，可能以删除');
}
$catid = $content_single['catid'];
$cat = $CATEGORY[$catid];
$category_single = $cat;
$cat_url_tmp = explode('/', $cat['url']);
$top_url = $cat_url_tmp[0].'/';
if($top_url == $cat['url'])
{
    $top_catid = $catid;
    $top_category_single = $category_single;
}
else
{
    require 'category.class.php';
    $category = new category();
    $top_category_single = $category->path_get_category($top_url);
    $top_catid = $top_category_single['catid'];
}
extract($content_single);
$page_title = $title .'  --  '.$cat['catname'] .'  --  '.$site_conf->get('SITE_NAME');
$css_file = 'chl.css';
include template('default', $CATEGORY[$catid]['s_temp']);
?>
